#ifndef __MOVING_BLOCKS_RAYCAST_RESULT_HPP__
#define __MOVING_BLOCKS_RAYCAST_RESULT_HPP__

#include "Engine/Vector3.hpp"
#include "Engine/Ray3.h"
#include "MovingBlock.h"

using namespace PocketSurvival::Engine;

namespace PocketSurvival
{
    struct MovingBlocksRaycastResult
    {
        Ray3 ray;
        MovingBlockSet *movingBlockSet = nullptr;
        float distance;

        inline Vector3 hitPoint();
    };

    inline Vector3 MovingBlocksRaycastResult::hitPoint()
    {
        return ray.Position + ray.Direction * distance;
    }
    
} // namespace PocketSurvival

#endif
